package net.sunofbeach.blog.services;

import net.sunofbeach.blog.pojo.SobUser;
import net.sunofbeach.blog.response.ResponseResult;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

public interface IUserService {

    ResponseResult initManagerAccount(SobUser sobUser, HttpServletRequest request);

    void createCaptcha(HttpServletResponse response) throws Exception;

    ResponseResult sendEmail(HttpServletRequest request, String type,String emailAddress,String captchaCode);


    ResponseResult register(SobUser sobUser, String emailCode, String captchaCode);

    ResponseResult doLogin(String captcha, SobUser sobUser, String from);

    SobUser checkSobUser();

    ResponseResult getUserInfo(String userId);

    ResponseResult checkEmail(String email);

    ResponseResult checkUserName(String userName);

    ResponseResult updateUserInfo(String userId, SobUser sobUser);

    ResponseResult deleteUserById(String userId);

    ResponseResult listUsers(int page, int size,String userName,String email);

    ResponseResult updateUserPassword(String verifyCode, SobUser sobUser);

    ResponseResult updateEmail(String email, String verifyCode);

    ResponseResult doLogout();

    ResponseResult getPcLoginQrCodeInfo();

    ResponseResult CheckQrCodeLoginState(String loginId);

    ResponseResult updateQrCodeLoginState(String loginId);

    ResponseResult parseToken();

    ResponseResult resetPassword(String userId, String password);

    ResponseResult getRegisterCount();

    ResponseResult checkEmailCode(String email, String emailCode, String captchaCode);

}
